import { Random } from "mockjs";
import { stringify } from "postcss";

const data = [
  {
    url:'/user/login',
    methods:'post',
    data:{
      code:200,
      data:{
        nickname:Random.cname(),
        token:Random.word(72)
      }
    }
  },{
    url:'/home/data',
    methods:'get',
    data:{
      code:200,
      data:{
        car:[
          { name:'未检车辆','value|9-999'   : 1 },
          { name:'已检车辆','value|99-999': 1 },
          { name:'中标车辆','value|9-999'    : 1 },
        ],
        people:{
          'zc|999-99999':1,
          zb:[
            { name:'涉军'  ,'value|9-99':1 },
            { name:'涉毒'  ,'value|9-99':1 },
            { name:'网逃'  ,'value|9-99':1 },
            { name:'涉访'  ,'value|9-99':1 },
            { name:'精神病','value|9-99':1 },
            { name:'其他'  ,'value|9-99':1 }
          ]
        }
      }
    }
  },{
    url:'/warning/info',
    methods:'get',
    data:{
      code:200,
      data:{
        "warning_peoples|0-9":[{
          'id|+1':1,
          name:'@cname',
          time:"@datetime('yyyy-MM-dd HH:mm:ss')",
          path:'@ctitle(7)站',
          card:"@string('number',18)"
        }],
        "warning_cars|0-5":[{
          'id|+1':100,
          name:"冀A@string('upper',5)  0@string('number',1)",
          time:"@datetime('yyyy-MM-dd HH:mm:ss')",
          path:'@ctitle(7)站'
        }]
      }
    }
  },{
    url:'/car/list',
    methods:'get',
    data:{
      code:200,
      data:{
        'baseinfo|15':[{
          'id|+1':56,
          card:"冀A@string('upper',5)",
          "cardtype|1":['类型A','类型B','类型C','类型D'],
          func:'处以@ctitle(7,21)',
          "cartype|1":['类型A','类型B','类型C','类型D'],
          "isnonono|1":['未中标','中标'],
          "isopen|1":[true,false],
          "isblack|1":[true,false],
          createtime:"@datetime('yyyy-MM-dd HH:mm:ss')",
          starttime:"@datetime('yyyy-MM-dd HH:mm:ss')",
          endtime:"@datetime('yyyy-MM-dd HH:mm:ss')",
        }],
        'total|30-999':1
      }
    }
  },{
    url:'/points/list',
    methods:'get',
    data:{
      code:200,
      data:{
        'points|50-100':[{
          'x|113-114.6':1,
          'y|37-38.6':1,
          title:'@ctitle(7)站',
        }]
      }
    }
  },{
    url:'/get/stalist',
    methods:'get',
    data:{
      code:200,
      data:{
        'baseinfo|25-120':[{
          'index|+1':1,
          path:'@ctitle(7)站',
          'txnum|156-9004':1,
          'gjnum|265-2156':1,
          'zbnum|156-1218':1
        }],
      }
    }
  },{
    url:'/load/load',
    methods:'get',
    data:{
      code:200,
      data:{}
    }
  }
]

export default data;